<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
    <meta http-equiv="X-UA-Compatible" content="IE=EmulateIE7" />
    <title>用户注册 - {$mysite.sitename}</title>
    <base href="{$basepath}login/" />
    <link href="Css/Inpublic.css" rel="stylesheet" type="text/css" />
    <link href="Css/newreg.css" rel="stylesheet" type="text/css" />
    <link href="css/boxy.css" rel="stylesheet" type="text/css" />
    <link href="/style/themes/icon.css" rel="stylesheet" type="text/css" />
    <link href="/style/themes/default/easyui.css" rel="stylesheet" type="text/css" />

    <script src="/js/jquery-1.4.4.min.js" type="text/javascript"></script>

    <script src="/js/jquery.easyui.min.js" type="text/javascript"></script>

    <link href="../yzm/jquery.realperson.css" rel="stylesheet" type="text/css" />

    <script src="../yzm/jquery.realperson.js" type="text/javascript"></script>

    <style type="text/css">
        input.text { background: none repeat scroll 0 0 #FFFFFF; border: 1px solid #C0C0C0; height: 16px; margin: 2px 0; padding: 5px 2px; }
        .lyb_yeji_note .yeji_note .btn input.tj_btn { background: url("images/btn_tjly.jpg") no-repeat scroll 0 0 transparent; border: 0 none; cursor: pointer; height: 25px; width: 66px; }
    </style>

    <script type="text/javascript">
        $(document).ready(function()
        {
            $("#btnSubmit").click(function()
            {
                //验证码
                var rightcode = "";

                $("#divCode span").each(function()
                {
                    rightcode += $(this).html();
                });
                if ($("#txtValidCode").val() != rightcode)
                {
                    alert("验证码不正确!");
                    $("#txtValidCode").focus();
                    return false;
                }

                $("#frm1").form({
                    url: "/ashx/postop.ashx?ac=customfrm&tbname=Accounts&op=insert",
                    onSubmit: function()
                    {
                        return $(this).form('validate');
                        // do some check
                        // return false to prevent submit;
                    },
                    success: function(data)
                    {
                        alert("发布成功！");
                        location.href = location.href;
                    }
                });
            });
        });
    </script>

</head>
<body>
    <vt:include file="../top.html" />
    <div id="regtop">
        <span><a href="/">
            <img src="../images/index/18logo.gif" /></a></span><p>
                如需帮助,请咨询 <a href="tencent://message/?uin=552431552&Site={$mysite.sitename}&Menu=yes">
                </a><b></b>或拨打<b>0571-87858619</b></p>
        <br class="clear" />
    </div>
    <div class="regstep">
        <span class="hot">1.填写注册信息</span><span>2.注册成功/验证邮箱</span><span>3.完善公司资料</span></div>
    <div class="regtitle">
        欢迎您注册{$mysite.sitename}!我们将为您提供优质的服务,并且保障您信息的隐私不被泄露<b>*</b>为必填项</div>
    <form id="frm1" method="post">
    <div class="regtable">
        <div>
            <dl>
                <dt>会员登录名<b>*</b></dt><dd><div class="incss">
                    <input name="loginid" id="txtUserName" type="text" required="true"   maxlength="18" class="easyui-validatebox  validatebox-text" validtype="length[6,18]"/></div>
                </dd>
            </dl>
            <dl class="inbox">
                <dt>密码<b>*</b></dt><dd><div class="incss">
                    <input name="password" id="txtPwd1" type="password" required="true"  class="easyui-validatebox  validatebox-text"  maxlength="18" /></div>
                </dd>
            </dl>
            <dl>
                <dt>再次输入密码<b>*</b></dt><dd><div class="incss">
                    <input name="filter"  id="txtPwd2" type="password" required="true"  class="easyui-validatebox  validatebox-text"  /></div>
                </dd>
            </dl>
            <dl>
                <dt>电子邮箱<b>*</b></dt><dd><div class="incss">
                    <input name="email" id="txtEmail" type="text" required="true"  class="easyui-validatebox  validatebox-text"  validtype="email" /></div>
                </dd>
            </dl>         
        </div>
        <div id="contactInfo">
            <dl>
                <dt>您的姓名<b>*</b></dt><dd><div class="incss">
                    <input name="truename" id="txtTrueName" type="text" onfocus="reg==true ? ShowText(this,4) : ''"
                        onblur="return r1.ChkTrueName()" /></div>
                </dd>
            </dl>
            <dl>
                <dt>您的性别<b>*</b></dt><dd><div class="radiocss">
                    <input name="sex" id="rbSex" value="1" type="radio" checked="checked" />
                    先生&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<input name="sex" id="Radio2" type="radio"
                        value="0" />
                    女士</div>
                </dd>
            </dl>
            <dl>
                <dt>会员职务<b>*</b></dt><dd><div class="incss">
                    <input name="yourjob" id="txtPartment" type="text" class="easyui-validatebox  validatebox-text"/></div>
                </dd>
            </dl>
            <dl>
                <dt>公司名称<b>*</b></dt><dd><div class="incss">
                    <input name="companyname" id="txtComName" type="text" required="true"   class="easyui-validatebox  validatebox-text"   /></div>
                </dd>
            </dl>           
            <dl>
                <dt>固定电话<b>*</b></dt><dd><div class="incss">                 
                    <input name="phone" id="txtTelPhone" style="width: 169px;" type="text" value="电话号码" onfocus="this.value='';" /></div>
                   
                </dd>
            </dl>
            <dl>
                <dt>公司传真<b>*</b></dt><dd><div class="incss">                 
                    <input name="fax" id="txtFax" 
                        style="width: 169px;" type="text" value="传真号码" onfocus="this.value='';" /></div>
                </dd>
            </dl>
            <dl>
                <dt>手机号码<b></b></dt><dd><div class="incss">
                    <input name="mobile" id="txtMobile" type="text" /></div>
                </dd>
            </dl>
            <dl>
                <dt>公司网址<b></b></dt><dd><div class="incss">
                    <input name="homepage" id="txtWebSite" type="text"/></div>
                </dd>
            </dl>
            <dl>
                <dt>QQ<b></b></dt><dd><div class="incss">
                    <input name="qq" id="txtQQ" type="text" /></div>
                </dd>
            </dl>
            <dl>
                <dt>MSN<b></b></dt><dd><div class="incss">
                    <input name="msn" id="txtMsn" type="text" /></div>
                </dd>
            </dl>
        </div>
        <div>
            <dl>
                <dt>验证码<b>*</b></dt><dd><div class="incss">
                    <input  id="txtValidCode" type="text" style="width: 40px; float: left;"
                        maxlength="4" />
                    <div id="divCode" class="incss" onclick="javascript:validteCode()" title="单击更换验证码"
                        style="float: left; cursor: pointer; background-color: White; width: 52px; text-align: center;
                        vertical-align: middle; margin-left: 2px; letter-spacing: 5px; border: solid 1px #B5B5B5">
                        <span></span><span></span><span></span><span></span>
                    </div>
                </div>
                </dd>
            </dl>
        </div>
        <p>
            <a id="bt3">点此阅读平台服务条款</a>
            <button id="btnSubmit">
                同意服务条款,提交注册信息</button>
                </p>
        <div id="dialog" style="display: none;">
            <div class="login-sev">
                {$mysite.sitename} 服 务 条 款</div>
            <div class="login-read">
                请仔细阅读本协议</div>
            <div class="login-supply">
                {$mysite.sitename}依据以下条件和条款提供您所享有的服务</div>
            <textarea>   
</textarea>
        </div>
        <br class="clear" />
    </div>
    </form>
    <vt:include file="../footer.html" />
</body>
</html>

<script type="text/javascript">
    function validteCode()
    {
        var codes = new Array(4);       //用于存储随机验证码
        var colors = new Array("Red", "Green", "Gray", "Blue", "Maroon", "Aqua", "Fuchsia", "Lime", "Olive", "Silver");
        for (var i = 0; i < codes.length; i++)
        {//获取随机验证码
            codes[i] = Math.floor(Math.random() * 10);
        }
        $("#divCode span").each(function(i)
        {
            $(this).html(codes[i]);
            $(this).css("color", colors[Math.floor(Math.random() * 10)]);
        });
    }
    validteCode();
</script>

